# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgbase=python-libewf-python
pkgname=('python2-libewf-python' 'python-libewf-python')
_pkgname=libewf-python
pkgver=20240506
pkgrel=2
pkgdesc='A library to access the Expert Witness Compression Format (EWF).'
arch=('x86_64' 'aarch64')
url='https://pypi.org/project/libewf-python/#files'
license=('LGPLv3+')
makedepends=('python2-setuptools' 'python-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('cbafea658e5b52aa775b64347909fb5261704832428f3360aa52e0204652f794fce5f9e07343525f7e02fa9c49f6d2affd57b5ad3739814f9dacd4e33e07e969')

package_python2-libewf-python() {
  depends=('python2')

  cd "libewf-$pkgver"

  python2 setup.py install --prefix=/usr --root="$pkgdir" --optimize=1
}

package_python-libewf-python() {
  depends=('python')

  cd "libewf-$pkgver"

  python setup.py install --prefix=/usr --root="$pkgdir" --optimize=1
}

